package kr.hkit.androidcomplete02.ch18;

import kr.hkit.androidcomplete02.R;
import kr.hkit.androidcomplete02.ch16.AlertDialogEx;
import kr.hkit.androidcomplete02.ch16.BundleDialogFragment;
import kr.hkit.androidcomplete02.ch16.CheckQuestionFrg;
import kr.hkit.androidcomplete02.ch16.CustomDialog;
import kr.hkit.androidcomplete02.ch16.DialogFragmentEx;
import kr.hkit.androidcomplete02.ch16.DialogTest;
import kr.hkit.androidcomplete02.ch16.DlgQuestionFrg;
import kr.hkit.androidcomplete02.ch16.RadioQuestionFrg;
import kr.hkit.androidcomplete02.ch16.ShowDialogEx;
import kr.hkit.androidcomplete02.ch16.TouchOutside;
import android.app.ListActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.Toast;

public class Ch18_AMain extends ListActivity {
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		
		ArrayAdapter<CharSequence> adapter = ArrayAdapter.createFromResource(
				this, R.array.chapter18, android.R.layout.simple_list_item_1);

		setListAdapter(adapter);
	}

	@Override
	protected void onListItemClick(ListView l, View v, int position, long id) {
		super.onListItemClick(l, v, position, id);

		Intent intent = null;

		switch (position) {

		case 0:
			intent = new Intent(getApplication(), OverlayEx.class);
			break;	

		}
		startActivity(intent);
	}

}
